<template>
    <div>
       <!--
       <mt-swipe :auto="4000" style="height:173px">
            <mt-swipe-item v-for="(item,key) in swiperList" :key="key">
                <img width="100%" :src="item.imgUrl">
            </mt-swipe-item>
        </mt-swipe>
        -->
        <swiper :swiperList="swiperList" :isfull="true"></swiper>
        <!--六宫格-->
        <ul class="mui-table-view mui-grid-view mui-grid-9">
            <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
                <router-link to="/home/newsList">
                    <router-view></router-view>
                    <img src="../../images/news.png" alt="">
                    <div class="mui-media-body">新闻情报</div>
                </router-link>
            </li>
            <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
                <router-link to="/home/PhotoList">
                    <img src="../../images/pic.png" alt="">
                    <div class="mui-media-body">图片分享</div>
                </router-link>
            </li>
            <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
                <router-link to="/home/goodslist">
                    <img src="../../images/shop.png" alt="">
                    <div class="mui-media-body">商品购买</div>
                </router-link>
            </li>
            <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
                <router-link to="/home">
                    <img src="../../images/msg.png" alt="">
                    <div class="mui-media-body">留言反馈</div>
                </router-link>
            </li>
            <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
                <router-link to="/home">
                    <img src="../../images/movie.png" alt="">
                    <div class="mui-media-body">视频专区</div>
                </router-link>
            </li>
            <li class="mui-table-view-cell mui-media mui-col-xs-4 mui-col-sm-3">
                <router-link to="/home">
                    <img src="../../images/contact.png" alt="">
                    <div class="mui-media-body">联系我们</div>
                </router-link>
            </li>
        </ul> 
    </div>
</template>

<script>
import {Toast} from 'mint-ui'
import swiper from '../subcomponents/swiper.vue'
export default {
    data(){
        return{
            swiperList : null,
        }
    },
    components:{
        swiper,
    },
    methods:{
        getSwipe(){
            this.$http.get('static/data.json').then((response) => {
                if(response.body.ret){
                    this.swiperList = response.body.data.swiperList;
                }else{
                    Toast('加载轮播图失败')
                }
                
            })
           
        }
    },
    created(){
        this.getSwipe();
    }
}
</script>
<style scoped>
 .mui-grid-view ,.mui-grid-9{
    background: white;
    border: none;
}
.mui-grid-view.mui-grid-9 .mui-table-view-cell{
    border : none;
    width: 33%
}
li img{
    width:70%;
    
}
.mui-media-body{
    font-size: 13px
}
</style>
